import 'package:wanxiang_app/generated/json/base/json_field.dart';
import 'package:wanxiang_app/generated/json/pay_list_entity.g.dart';
import 'dart:convert';

@JsonSerializable()
class PayListEntity {
	late int code;
	late String msg;
	late List<PayListData> data;

	PayListEntity();

	factory PayListEntity.fromJson(Map<String, dynamic> json) => $PayListEntityFromJson(json);

	Map<String, dynamic> toJson() => $PayListEntityToJson(this);

	@override
	String toString() {
		return jsonEncode(this);
	}
}

@JsonSerializable()
class PayListData {
	late int id;
	@JSONField(name: "user_id")
	late int userId;
	late String time;
	late String amount;
	late String way;
	late int status;

	PayListData();

	factory PayListData.fromJson(Map<String, dynamic> json) => $PayListDataFromJson(json);

	Map<String, dynamic> toJson() => $PayListDataToJson(this);

	@override
	String toString() {
		return jsonEncode(this);
	}
}